package com.atguigu.tingshu.album.service.impl;

import com.atguigu.tingshu.album.mapper.AlbumAttributeValueMapper;
import com.atguigu.tingshu.album.service.AlbumAttributeValueService;
import com.atguigu.tingshu.model.album.AlbumAttributeValue;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class AlbumAttributeValueServiceImpl extends ServiceImpl<AlbumAttributeValueMapper,AlbumAttributeValue> implements AlbumAttributeValueService {
    @Autowired
    private AlbumAttributeValueMapper albumAttributeValueMapper;
    /**
     * 查询专辑目录标签列表
     *
     * @param albumId 专辑ID
     * */
    @Override
    public List<AlbumAttributeValue> findAlbumAttributeValue(Long albumId) {
        List<AlbumAttributeValue> albumAttributeValueList = albumAttributeValueMapper.selectList(new LambdaQueryWrapper<AlbumAttributeValue>().eq(AlbumAttributeValue::getAlbumId, albumId));
        return albumAttributeValueList;
    }
}
